package com.neuedu.grainsapi.controller;

import com.neuedu.grainsapi.pojo.NagrPcap;
import com.neuedu.grainsapi.service.NagrPcapService;
import com.neuedu.grainsapi.util.ResponseResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
public class NagrPcapController {
    @Autowired
    private NagrPcapService nagrPcapService;
    @GetMapping("/queryNagrPcap")
    public ResponseResult<List<NagrPcap>> queryNagrPcap(){
        List<NagrPcap> nagrPcaps = nagrPcapService.queryNagrPcap();
        return new ResponseResult<>("200","yes",nagrPcaps);
    }
}
